﻿using System;
namespace Dynamics.NAV.Metro.Data
{
    public interface IDynamicsNavApi
    {
        System.Collections.Generic.IList<NavCompany> Companies { get; }
        bool Connect(bool reconnect);
        bool Connected { get; }
        NavCompany CurrentCompany { get; set; }
        System.Threading.Tasks.Task<int> GetItemCount(int maxCount, string serviceName, string filter);
        System.Threading.Tasks.Task<T> GetItems<T>(int index, int perPage, string serviceName, string filter);
        System.Threading.Tasks.Task<T> GetItems<T>(int index, string serviceName, string filter);
    }
}
